package extension

import android.view.View
import kotlinx.coroutines.ExperimentalCoroutinesApi
import kotlinx.coroutines.suspendCancellableCoroutine

suspend fun View.await() = suspendCancellableCoroutine<View> {
    post {
        it.resume(this, null)
    }
}
